import 'dart:convert';
/// String 加密 解密工具类
/// @author: dingwen
/// @date: 2020/12/30

class StringUtil{
  /// Base64加密
  static String encodeBase64(String data) {
    var content = utf8.encode(data);
    var digest = base64Encode(content);
    return digest;
  }

  ///Base64解密
  static String decodeBase64(String data) {
    return String.fromCharCodes(base64Decode(data));
  }
}